package com.block.datapush.model.result;

import lombok.Data;

@Data
public class FilterHandlerResult {

    public boolean success;

    public String code;

    public String message;

    public static FilterHandlerResult success(){
        FilterHandlerResult handlerResult = new FilterHandlerResult();
        handlerResult.setSuccess(true);
        return handlerResult;
    }

    public static FilterHandlerResult error(String code, String message){
        FilterHandlerResult handlerResult = new FilterHandlerResult();
        handlerResult.setSuccess(false);
        handlerResult.setCode(code);
        handlerResult.setMessage(message);
        return handlerResult;
    }

}
